{% extends 'base.html' %} {% load static %} {% block title %}{% if form.instance.pk %}Edit Department{% else %}Add New Department{% endif %} | TaskFlow{% endblock %} {% block content %}

{% if form.instance.pk %}Update Department{% else %}Create New Department{% endif %}

{% csrf_token %} {% if form.non_field_errors %} {% endif %}
{{ form.name }}
{% if form.name.help_text %} {{ form.name.help_text }} {% endif %} {% if form.name.errors %}
{{ form.name.errors|join:", " }}
{% endif %}
{{ form.parent }}
{% if form.parent.help_text %} {{ form.parent.help_text }} {% endif %} {% if form.parent.errors %}
{{ form.parent.errors|join:", " }}
{% endif %}
{% if form.manager %}
{{ form.manager }}
{% if form.manager.help_text %} {{ form.manager.help_text }} {% endif %} {% if form.manager.errors %}
{{ form.manager.errors|join:", " }}
{% endif %}
{% endif %}
{{ form.description }}
{% if form.description.help_text %} {{ form.description.help_text }} {% endif %} {% if form.description.errors %}
{{ form.description.errors|join:", " }}
{% endif %}
Cancel
{% if form.instance.pk and perms.users.delete_department %} Delete Department {% endif %}
Quick Help
Naming Guidelines

Use clear, descriptive names that reflect the department's function or location.
Examples: "Marketing", "Sales - North Region", "IT - Infrastructure"

Organizational Structure

Select a parent department to create a hierarchical structure. This helps in organizing departments into logical groups and sub-groups.

Description Tips
  • Briefly describe the department's primary purpose
  • List key responsibilities and functions
  • Include any special notes or considerations
Need Help?

Contact the system administrator if you need assistance with department setup.

Contact Support
{% endblock %} {% block extra_js %} {% endblock %}